//
//  PTGetIMEI.swift
//  PTWatch Watch App
//
//  Created by sc-chen on 2023/9/20.
//

import SwiftUI

struct PTGetIMEI: View {
    
    @State private var content = "读取设备唯一可识别数据"
    
    @State private var isShowingHUD = false
    @State private var detailTxt = "不支持开发功能"
    
    var body: some View {
        /*ZStack {
            VStack {
                Button {content = "无法读取设备唯一可识别数据"
                    showHud()
                } label: {
                    Text(content)
                        .frame(maxWidth: .infinity)
                        .padding()
                        .foregroundColor(.blue)
                        .overlay(
                            RoundedRectangle(cornerRadius: 10)
                                .stroke(Color.blue, lineWidth: 1)
                        )
                }
                .buttonStyle(.borderless)
                .padding()
                Spacer()
            }
            PTProgressHud(isPresented: $isShowingHUD, text: $detailTxt)
        }.onAppear(){
            showHud()
        }*/
        
        Text("不支持读取IMEI的开发功能")
    }
    
    private func showHud() {
        isShowingHUD = true
        DispatchQueue.main.asyncAfter(deadline: .now()+2){
            isShowingHUD = false
        }
    }
}

struct PTGetIMEI_Previews: PreviewProvider {
    static var previews: some View {
        PTGetIMEI()
    }
}
